import { PaginationOptions } from '@/types/interface';
import { request } from '@/utils/request';

const url = '/api/console/site-model';
export default {
  list: (params: PaginationOptions) => request.get({ url, params }),
  add: (data: any) => request.post({ url, data }),
  update: (data: any) => request.patch({ url, data }),
  del: (id: number) => request.delete({ url: `${url}/${id}` }),
  detail: (id: number) => request.get({ url: `${url}/${id}` }),
  display: (id: number, val: number) => request.patch({ url: `${url}/display/${id}/${val}` }),
};
